package cn.yangliu.springbatch.entity;

import lombok.EqualsAndHashCode;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.sql.Timestamp;

/**
 * the type of springbatch
 *
 * <p>
 * .
 *
 * @author 杨柳
 * @date 2021-07-13
 */
@Entity
@EqualsAndHashCode
@Table(name = "batch_job_execution")
public class BatchJobExecution {

    private Long jobExecutionId;
    private Long jobInstanceId;
    private Long version;
    private Timestamp createTime;
    private Timestamp startTime;
    private Timestamp endTime;
    private String status;
    private String exitCode;
    private String exitMessage;
    private Timestamp lastUpdated;
    private String jobConfigurationLocation;


    /**
     * instance member witch named jobExecutionId‘s getter
     * <p>
     * for get field witch named jobExecutionId’s value
     *
     * @return jobExecutionId
     */
    @Id
    @Column(name = "JOB_EXECUTION_ID", nullable = false)
    public Long getJobExecutionId() {
        return jobExecutionId;
    }

    /**
     * instance member witch named jobExecutionId's setter
     * for set field witch named jobExecutionId's value
     *
     * @param jobExecutionId jobExecutionId
     */
    public void setJobExecutionId(long jobExecutionId) {
        this.jobExecutionId = jobExecutionId;
    }

    /**
     * instance member witch named jobExecutionId's setter
     * for set field witch named jobExecutionId's value
     *
     * @param jobExecutionId jobExecutionId
     */
    public BatchJobExecution setJobExecutionId(Long jobExecutionId) {
        this.jobExecutionId = jobExecutionId;
        return this;
    }

    /**
     * instance member witch named jobInstanceId‘s getter
     * <p>
     * for get field witch named jobInstanceId’s value
     *
     * @return jobInstanceId
     */
    @Basic
    @Column(name = "JOB_INSTANCE_ID")
    public Long getJobInstanceId() {
        return jobInstanceId;
    }

    /**
     * instance member witch named jobInstanceId's setter
     * for set field witch named jobInstanceId's value
     *
     * @param jobInstanceId jobInstanceId
     */
    public BatchJobExecution setJobInstanceId(Long jobInstanceId) {
        this.jobInstanceId = jobInstanceId;
        return this;
    }

    /**
     * instance member witch named version‘s getter
     * <p>
     * for get field witch named version’s value
     *
     * @return version
     */
    @Basic
    @Column(name = "VERSION")
    public Long getVersion() {
        return version;
    }

    /**
     * instance member witch named version's setter
     * for set field witch named version's value
     *
     * @param version version
     */
    public void setVersion(Long version) {
        this.version = version;
    }

    /**
     * instance member witch named createTime‘s getter
     * <p>
     * for get field witch named createTime’s value
     *
     * @return createTime
     */
    @Basic
    @Column(name = "CREATE_TIME", nullable = false)
    public Timestamp getCreateTime() {
        return createTime;
    }

    /**
     * instance member witch named createTime's setter
     * for set field witch named createTime's value
     *
     * @param createTime createTime
     */
    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
        
    }

    /**
     * instance member witch named startTime‘s getter
     * <p>
     * for get field witch named startTime’s value
     *
     * @return startTime
     */
    @Basic
    @Column(name = "START_TIME")
    public Timestamp getStartTime() {
        return startTime;
    }

    /**
     * instance member witch named startTime's setter
     * for set field witch named startTime's value
     *
     * @param startTime startTime
     */
    public void setStartTime(Timestamp startTime) {
        this.startTime = startTime;
        
    }

    /**
     * instance member witch named endTime‘s getter
     * <p>
     * for get field witch named endTime’s value
     *
     * @return endTime
     */
    @Basic
    @Column(name = "END_TIME")
    public Timestamp getEndTime() {
        return endTime;
    }

    /**
     * instance member witch named endTime's setter
     * for set field witch named endTime's value
     *
     * @param endTime endTime
     */
    public void setEndTime(Timestamp endTime) {
        this.endTime = endTime;
        
    }

    /**
     * instance member witch named status‘s getter
     * <p>
     * for get field witch named status’s value
     *
     * @return status
     */
    @Basic
    @Column(name = "STATUS", length = 10)
    public String getStatus() {
        return status;
    }

    /**
     * instance member witch named status's setter
     * for set field witch named status's value
     *
     * @param status status
     */
    public void setStatus(String status) {
        this.status = status;
        
    }

    /**
     * instance member witch named exitCode‘s getter
     * <p>
     * for get field witch named exitCode’s value
     *
     * @return exitCode
     */
    @Basic
    @Column(name = "EXIT_CODE", length = 2500)
    public String getExitCode() {
        return exitCode;
    }

    /**
     * instance member witch named exitCode's setter
     * for set field witch named exitCode's value
     *
     * @param exitCode exitCode
     */
    public void setExitCode(String exitCode) {
        this.exitCode = exitCode;
        
    }

    /**
     * instance member witch named exitMessage‘s getter
     * <p>
     * for get field witch named exitMessage’s value
     *
     * @return exitMessage
     */
    @Basic
    @Column(name = "EXIT_MESSAGE", length = 2500)
    public String getExitMessage() {
        return exitMessage;
    }

    /**
     * instance member witch named exitMessage's setter
     * for set field witch named exitMessage's value
     *
     * @param exitMessage exitMessage
     */
    public void setExitMessage(String exitMessage) {
        this.exitMessage = exitMessage;
        
    }

    /**
     * instance member witch named lastUpdated‘s getter
     * <p>
     * for get field witch named lastUpdated’s value
     *
     * @return lastUpdated
     */
    @Basic
    @Column(name = "LAST_UPDATED")
    public Timestamp getLastUpdated() {
        return lastUpdated;
    }

    /**
     * instance member witch named lastUpdated's setter
     * for set field witch named lastUpdated's value
     *
     * @param lastUpdated lastUpdated
     */
    public void setLastUpdated(Timestamp lastUpdated) {
        this.lastUpdated = lastUpdated;
        
    }

    /**
     * instance member witch named jobConfigurationLocation‘s getter
     * <p>
     * for get field witch named jobConfigurationLocation’s value
     *
     * @return jobConfigurationLocation
     */
    @Basic
    @Column(name = "JOB_CONFIGURATION_LOCATION", length = 2500)
    public String getJobConfigurationLocation() {
        return jobConfigurationLocation;
    }

    /**
     * instance member witch named jobConfigurationLocation's setter
     * for set field witch named jobConfigurationLocation's value
     *
     * @param jobConfigurationLocation jobConfigurationLocation
     */
    public void setJobConfigurationLocation(String jobConfigurationLocation) {
        this.jobConfigurationLocation = jobConfigurationLocation;
        
    }

}
